public with sharing class Sharing{
    public static Integer getAccounts(){
        Account[] accounts = [Select Id,name from Account];
        return (accounts.size());
    }
}